
import java.io.*;

public class IO {
    public static void dump(InputStream src, OutputStream dest)
            throws IOException {
        try (InputStream input = src; OutputStream output = dest) {
            byte[] data = new byte[1024];
            int k=input.read(data,0,data.length);
            System.out.println(new String(data));
            for(int i=0;i<data.length;i++) {
                if(data[i]!=0) {
                    System.out.printf("%c ",data[i]);
                    if(i%16==0&&i!=0) {
                        System.out.println();
                    }
                }
            }
            System.out.println();
            int[] in=new int[data.length];
            for(int i=0;i<in.length;i++) {
                in[i]=data[i]&0xff;
            }
            for(int i=0;i<data.length;i++) {
                if(in[i]!=0) {
                    System.out.print(Integer.toString(in[i],0x10)+" ");
                    if(i%16==0&&i!=0) {
                        System.out.println();
                    }
                }
            }
            System.out.println();
        }
    }
}